package com.liruo.learn.log.spring.standard.logback;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

@SpringBootApplication
public class StandardLogbackApplication {

    public static void main(String[] args) {
        SpringApplication.run(StandardLogbackApplication.class, args);
        Logger logger = LoggerFactory.getLogger("com.liruo.learn.log.spring.logback");
        logAll(logger, "run springApplication");
    }
    private  static void logAll(Logger logger, String msg) {
        logger.error("[error]{}", msg);
        logger.warn("[warn]{}", msg);
        logger.info("[info]{}", msg);
        logger.debug("[debug]{}", msg);
        logger.trace("[trace]{}", msg);
    }

}
